package chain.leave;

public class Main {

	public static void main(String[] args) {

		Handler director = new Director("主管");

		Handler manager = new Manager("部门经理");

		Handler topManager = new TopManager("总经理");

		director.setNextHandler(manager);

		manager.setNextHandler(topManager);

		LeaveRequest request = new LeaveRequest();
		request.setNumOfDays(5);
		director.process(request);

		request.setNumOfDays(10);
		director.process(request);

		request.setNumOfDays(15);
		director.process(request);

	}

}
